package com.fintech.datagroud.dao.decision;

import java.util.Map;

import org.apache.ibatis.annotations.Param;

public interface DecisionDataMapper {
	/**
	 * 查询决策需要的数据
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectDecisionDataMapper(String loanId);
	
	/**
	 * 查询有盾决策需要数据
	 * @param reqNo
	 * @return
	 */
	Map<String, Object> selectYDDecisionDataMapper(String reqNo);
	
	/**
	 * 查询魔蝎通话次数相关数据
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectMXCallNumberDataMapper(String loanId);
	
	/**
	 * 通讯录备注为空的联系人个数
	 * @param userId
	 * @return
	 */
	Integer selectLinkMansRemarkEmptyNumber(String userId);
	
	/**
	 * 查询有盾借贷行为数据
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectLoanBehaviorData(String loanId);
	
	/**
	 * 近七天被叫且联系人不在通讯录里的次数
	 * @param loanId
	 * @return
	 */
	Integer select7dCalledNolinkCount(@Param("loanId") String loanId, @Param("reqNo") String reqNo, @Param("userId") String userId);
	
	/**
	 * 短信次数
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectMessageCount(String loanId);
	
	/**
	 * 12599（语音信箱）被叫出现次数
	 * @param loanId
	 * @return
	 */
	Integer select12599CalledCount(@Param("loanId") String loanId, @Param("reqNo") String reqNo);
	
	/**
	 * 查询设备相关信息
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectDeviceInfo(@Param("loanId") String loanId);
	
	
	/**
	 * 有盾其他信息
	 * @param loanId
	 * @return
	 */
	Map<String, Object> selectOtherLinkDeviceDetail(@Param("loanId") String loanId);
	Map<String, Object> selectLinkDeviceDetail(@Param("loanId") String loanId);
	
	/**
	 * 查询归属地个数
	 * @param loanId
	 * @return
	 * @author:wujunfeng
	 */
	String selectlocationNum(@Param("loanId") String loanId);
}
